package cn.tedu.boke.portal.mapper;

import cn.tedu.boke.portal.model.Comment;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

/**
* <p>
    * 评论 Mapper 接口
    * </p>
*
* @author tedu.cn
* @since 2021-11-04
*/
    @Repository
    public interface CommentMapper extends BaseMapper<Comment> {
    @Select("SELECT COUNT(post_id) FROM comment WHERE post_id=#{id}")
    int commentnum(Integer id);
    }
